/*
 * @Author: lg
 * @Date: 2024-05-21 16:29:23
 * @LastEditors: lg
 * @LastEditTime: 2024-05-23 09:22:11
 * @Description:
 * @FilePath: \bi-main\src\components\upload-file\src\api\oss.js
 */
import axios from 'axios';

/**
 * 获取用户根目录下文档列表
 */
export function getOssToken(dataSource) {
  return axios.get('/document/v1/oss/ignores/token', {
    params: { dataSource }
  });
}

/* 根据附件Ids，获取附件列表 批量 */
export const getAnnexQuery = (data) =>
  axios.post('/document/v1/annex/query', data);

/* 根据附件Ids，批量删除附件 批量 */
export const batchDeleteAnnex = (data) =>
  axios.post('/document/v1/annex/batch/delete', data);

/* 获取预览相关地址 */
export const getPreviewConfigApi = (data) =>
  axios.get('/document/v1/ignores/properties', {
    params: data
  });
